package com.kamistoat.meimeimall.meimeimallorder.feign;

import com.kamistoat.meimeimall.common.To.memberTo.MemberReceiveAddressTo;
import com.kamistoat.meimeimall.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * 已弃用 Feign接口
 */
@FeignClient("meimeimall-member")
public interface MemberFeignService {

    /**
     * 远程查询用户id下所有吧地址
     * @param memberId
     * @return
     */
    @GetMapping("meimeimallmember/memberreceiveaddress/getOrderAddress")
    List<MemberReceiveAddressTo> getOrderAddress(@RequestParam Long memberId);

    /**
     * 远程查询地址id的地址
     * @param attrId
     * @return
     */
    @GetMapping("meimeimallmember/memberreceiveaddress/getAddressId")
    MemberReceiveAddressTo getAddressId(@RequestParam Long attrId);

    /**
     * 运费
     * @param attrId
     * @return
     */
    @GetMapping("meimeimallmember/memberreceiveaddress/fare")
    R getFare(@RequestParam Long attrId);
}
